<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>InfAdoptedSessionRecord</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.76.0">
<link rel="home" href="index.html" title="libinfinity-0.4 Reference Manual">
<link rel="up" href="ch03.html" title="Libinfinity's adOPTed implementation">
<link rel="prev" href="libinfinity-0.4-InfAdoptedStateVector.html" title="InfAdoptedStateVector">
<link rel="next" href="ch04.html" title="Libinfinity client side API">
<meta name="generator" content="GTK-Doc V1.15 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="libinfinity-0.4-InfAdoptedStateVector.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="ch03.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">libinfinity-0.4 Reference Manual</th>
<td><a accesskey="n" href="ch04.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#InfAdoptedSessionRecord.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#InfAdoptedSessionRecord.description" class="shortcut">Description</a>
                   | 
                  <a href="#InfAdoptedSessionRecord.object-hierarchy" class="shortcut">Object Hierarchy</a>
                   | 
                  <a href="#InfAdoptedSessionRecord.properties" class="shortcut">Properties</a>
</td></tr>
</table>
<div class="refentry" title="InfAdoptedSessionRecord">
<a name="InfAdoptedSessionRecord"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="InfAdoptedSessionRecord.top_of_page"></a>InfAdoptedSessionRecord</span></h2>
<p>InfAdoptedSessionRecord — Create a record of a session</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1" title="Stability Level">
<a name="InfAdoptedSessionRecord.stability-level"></a><h2>Stability Level</h2>
Unstable, unless otherwise indicated
</div>
<div class="refsynopsisdiv" title="Synopsis">
<a name="InfAdoptedSessionRecord.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
#include &lt;libinfinity/adopted/inf-adopted-session-record.h&gt;

                    <a class="link" href="InfAdoptedSessionRecord.html#InfAdoptedSessionRecord-struct" title="InfAdoptedSessionRecord">InfAdoptedSessionRecord</a>;
                    <a class="link" href="InfAdoptedSessionRecord.html#InfAdoptedSessionRecordClass" title="InfAdoptedSessionRecordClass">InfAdoptedSessionRecordClass</a>;
<a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="returnvalue">InfAdoptedSessionRecord</span></a> * <a class="link" href="InfAdoptedSessionRecord.html#inf-adopted-session-record-new" title="inf_adopted_session_record_new ()">inf_adopted_session_record_new</a>
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSession.html" title="InfAdoptedSession"><span class="type">InfAdoptedSession</span></a> *session</code></em>);
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="InfAdoptedSessionRecord.html#inf-adopted-session-record-start-recording" title="inf_adopted_session_record_start_recording ()">inf_adopted_session_record_start_recording</a>
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> *record</code></em>,
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *filename</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="InfAdoptedSessionRecord.html#inf-adopted-session-record-stop-recording" title="inf_adopted_session_record_stop_recording ()">inf_adopted_session_record_stop_recording</a>
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> *record</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="InfAdoptedSessionRecord.html#inf-adopted-session-record-is-recording" title="inf_adopted_session_record_is_recording ()">inf_adopted_session_record_is_recording</a>
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> *record</code></em>);
</pre>
</div>
<div class="refsect1" title="Object Hierarchy">
<a name="InfAdoptedSessionRecord.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
   +----InfAdoptedSessionRecord
</pre>
</div>
<div class="refsect1" title="Properties">
<a name="InfAdoptedSessionRecord.properties"></a><h2>Properties</h2>
<pre class="synopsis">
  "<a class="link" href="InfAdoptedSessionRecord.html#InfAdoptedSessionRecord--session" title='The "session" property'>session</a>"                  <a class="link" href="InfAdoptedSession.html" title="InfAdoptedSession"><span class="type">InfAdoptedSession</span></a>*    : Read / Write / Construct Only
</pre>
</div>
<div class="refsect1" title="Description">
<a name="InfAdoptedSessionRecord.description"></a><h2>Description</h2>
<p>
<a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> creates a record of a <a class="link" href="InfAdoptedSession.html" title="InfAdoptedSession"><span class="type">InfAdoptedSession</span></a>. It
records every modification made to the session from the beginning of its
own lifetime to the end of its lifetime.
</p>
<p>
It does not record user status changes and thus the recorded session
cannot reliably be replayed with all user information. It's main purpose is
to make it easy to reproduce bugs in libinfinity. However, it might be
extended in the future.
</p>
<p>
To replay a record, use the tool inf-test-text-replay in the infinote
test suite.
</p>
</div>
<div class="refsect1" title="Details">
<a name="InfAdoptedSessionRecord.details"></a><h2>Details</h2>
<div class="refsect2" title="InfAdoptedSessionRecord">
<a name="InfAdoptedSessionRecord-struct"></a><h3>InfAdoptedSessionRecord</h3>
<pre class="programlisting">typedef struct _InfAdoptedSessionRecord InfAdoptedSessionRecord;</pre>
<p>
<a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> is an opaque data type. You should only access it
via the public API functions.
</p>
</div>
<hr>
<div class="refsect2" title="InfAdoptedSessionRecordClass">
<a name="InfAdoptedSessionRecordClass"></a><h3>InfAdoptedSessionRecordClass</h3>
<pre class="programlisting">typedef struct {
} InfAdoptedSessionRecordClass;
</pre>
<p>
This structure does not contain any public fields.
</p>
</div>
<hr>
<div class="refsect2" title="inf_adopted_session_record_new ()">
<a name="inf-adopted-session-record-new"></a><h3>inf_adopted_session_record_new ()</h3>
<pre class="programlisting"><a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="returnvalue">InfAdoptedSessionRecord</span></a> * inf_adopted_session_record_new
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSession.html" title="InfAdoptedSession"><span class="type">InfAdoptedSession</span></a> *session</code></em>);</pre>
<p>
Creates a new <a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a>, recording <em class="parameter"><code>session</code></em>. To start
recording, call <a class="link" href="InfAdoptedSessionRecord.html#inf-adopted-session-record-start-recording" title="inf_adopted_session_record_start_recording ()"><code class="function">inf_adopted_session_record_start_recording()</code></a>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>session</code></em> :</span></p></td>
<td>A <a class="link" href="InfAdoptedSession.html" title="InfAdoptedSession"><span class="type">InfAdoptedSession</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> A new <a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a>.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="inf_adopted_session_record_start_recording ()">
<a name="inf-adopted-session-record-start-recording"></a><h3>inf_adopted_session_record_start_recording ()</h3>
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            inf_adopted_session_record_start_recording
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> *record</code></em>,
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *filename</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
<p>
Starts to record the session. Make sure the session is not already closed
before calling this function. If an error occurs, such as if <em class="parameter"><code>filename</code></em>
could not be opened, then the function returns <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> and <em class="parameter"><code>error</code></em> is set.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>record</code></em> :</span></p></td>
<td>A <a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>filename</code></em> :</span></p></td>
<td>The file in which to store the record.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
<td>Location to store error information, if any.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the session is started to be recorded, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> on
error.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="inf_adopted_session_record_stop_recording ()">
<a name="inf-adopted-session-record-stop-recording"></a><h3>inf_adopted_session_record_stop_recording ()</h3>
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            inf_adopted_session_record_stop_recording
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> *record</code></em>,
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
<p>
Stops the recording of the current session, which must have been started
previously via <a class="link" href="InfAdoptedSessionRecord.html#inf-adopted-session-record-start-recording" title="inf_adopted_session_record_start_recording ()"><code class="function">inf_adopted_session_record_start_recording()</code></a>. If an error
occurs, then the function returns <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> and <em class="parameter"><code>error</code></em> is set. Note that even
if an error occurs, then the recording is stopped as well. However, the
file might not have been completely written to disk, so you should still
show any errors during this function to the user.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>record</code></em> :</span></p></td>
<td>A <a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td>
<td>Location to store error information, if any.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the recording has been stored successfully, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>
otherwise.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" title="inf_adopted_session_record_is_recording ()">
<a name="inf-adopted-session-record-is-recording"></a><h3>inf_adopted_session_record_is_recording ()</h3>
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            inf_adopted_session_record_is_recording
                                                        (<em class="parameter"><code><a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a> *record</code></em>);</pre>
<p>
Returns whether <em class="parameter"><code>record</code></em> is currently recording a session.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>record</code></em> :</span></p></td>
<td>A <a class="link" href="InfAdoptedSessionRecord.html" title="InfAdoptedSessionRecord"><span class="type">InfAdoptedSessionRecord</span></a>.
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td> Whether <em class="parameter"><code>record</code></em> currently records the session.
</td>
</tr>
</tbody>
</table></div>
</div>
</div>
<div class="refsect1" title="Property Details">
<a name="InfAdoptedSessionRecord.property-details"></a><h2>Property Details</h2>
<div class="refsect2" title='The "session" property'>
<a name="InfAdoptedSessionRecord--session"></a><h3>The <code class="literal">"session"</code> property</h3>
<pre class="programlisting">  "session"                  <a class="link" href="InfAdoptedSession.html" title="InfAdoptedSession"><span class="type">InfAdoptedSession</span></a>*    : Read / Write / Construct Only</pre>
<p>The session to record.</p>
</div>
</div>
<div class="refsect1" title="See Also">
<a name="InfAdoptedSessionRecord.see-also"></a><h2>See Also</h2>
<a class="link" href="InfAdoptedSession.html" title="InfAdoptedSession"><span class="type">InfAdoptedSession</span></a>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.15</div>
</body>
</html>